package com.okami.reflex;

import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;

/**
 * @author: TanJingyu
 * @create: 2020-12-26 11:02
 **/
public class Test {
    public static void main(String[] args) throws NoSuchMethodException, InvocationTargetException, IllegalAccessException {
        Dog dog = new Dog();
        Method show = dog.getClass().getDeclaredMethod("show");
        show.invoke(dog);
    }
}
